package cn.spring01;



import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Test {
	public static void main(String[] args) {
		
		ApplicationContext ctx=new ClassPathXmlApplicationContext("applicationContext.xml");
		Student stu=(Student)ctx.getBean("stu");
		System.out.println(stu);
		System.out.println(stu.getName());
		System.out.println(stu.getAge());
		System.out.println(stu.getCar().getBrand());

	}

}
